<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <!-- 1.引入vue3原代码 -->
    <script src="https://unpkg.com/vue@3/dist/vue.global.js"></script>
    <!-- 2.准备容器 -->
    <div id="app">
    <h1>{{ message }}</h1>
    <p>My name is {{ object.name }},{{ object.age }} years old this year</p>
    <p>函数demo的返回值是{{ demo() }}</p>
    </div>
     <!-- 3.创建vue3应用并提供数据 -->
    <script>
        Vue.createApp({
            setup(props) {
                const message = "Hello World";
                const object = {
                    name: "九转苍翎",
                    age: 18
                }
                const demo = () => "逆天而行";
                return {
                    message,
                    object,
                    demo
                }
            }
        }).mount("#app")
    </script>
</body>
</html>